package com.huilian.iotbox.admin.wap.service.impl;

import com.alibaba.fastjson.JSON;
import com.alibaba.fastjson.JSONObject;
import com.huilian.iotbox.admin.wap.dao.CommodityStockDao;
import com.huilian.iotbox.admin.wap.service.CommodityStockRecordItemService;
import com.huilian.iotbox.admin.wap.service.CommodityStockRecordService;
import com.huilian.iotbox.admin.wap.service.CommodityStockService;
import com.huilian.iotbox.admin.wap.service.UserService;
import com.huilian.iotbox.data.dto.CommodityStockDto;
import com.huilian.iotbox.data.dto.CommodityStockRecordDto;
import com.huilian.iotbox.data.dto.CommodityStockRecordItemDto;
import com.huilian.iotbox.data.enums.CommodityStockRecordSecondTypeEnum;
import com.huilian.iotbox.data.po.CommodityStock;
import com.huilian.iotbox.data.po.User;
import com.huilian.iotbox.data.utils.RedisCache;
import com.huilian.iotbox.data.utils.Util;
import com.huilian.iotbox.data.vo.CommodityStockVo;
import com.huilian.tool.common.config.WeixinConfig;
import com.huilian.tool.redis.ToolRedisKey;
import com.huilian.tool.weixin.service.WeixinService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Service;
import org.springframework.util.ObjectUtils;

import javax.annotation.Resource;
import java.math.BigDecimal;
import java.text.SimpleDateFormat;
import java.util.Date;

@Service
@Slf4j
public class CommodityStockServiceImpl implements CommodityStockService {
    @Resource
    private CommodityStockDao commodityStockDao;


    @Override
    public Integer updateByCommodityId(CommodityStock commodityStock) {
        return commodityStockDao.updateByCommodityId(commodityStock);
    }

}
